ci: test on more python versions#926
Merged
KowalskiThomas merged 3 commits intomasterfrom Apr 8, 2026
Merged
Conversation
3a6e111 to
028a289
Compare
armcburney
reviewed
Apr 7, 2026
Comment on lines
+186
to
+191
| if content and result.headers.get("Content-Encoding") == "gzip": | ||
| try: | ||
| content = zlib.decompress(content, zlib.MAX_WBITS | 16) | ||
| except zlib.error: | ||
| pass | ||
|
|
armcburney
approved these changes
Apr 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of the Change
This updates the GHA configuration to run tests on a wider array of Python versions:
Python 2.7 because we still have compatibility with it so it needs to workremoved this for now because it's not available forsetup-pythonanymorePython 3.4 because it predates the introduction of type hints and thus gives an important signal about type annotations not being a problemremoved this for now because it's not available forsetup-pythonanymoreIn order for tests to pass on more recent versions of Python, I had to
gzip-compressed API responses (becausevcrpynow doesn't decompress transparently)mix_stderron versions of Python more recent than3.10because theClickversion we get there doesn't have this parameter anymore. I'm not sure what better way to do that there is to be honest...locals()because since 3.10locals()returns a new dict at each call, making the previous approach just not work.I do plan to add support for Python 2.7 and 3.4 back (especially because I think the code currently on
masterdoesn't work with 2.7), but I want to keep this PR reasonably-sized.Note I tried to add the label to run integration tests (that run against the real Datadog API) but it turns out those apparently have stopped working since they were working (in 2020) because the Datadog API changed. I updated the Python version there as well so that at least they can start.